home *** CD-ROM | disk | FTP | other *** search
- on enterFrame
- set xCenter to ((the left of sprite 3 + the right of sprite 3) / 2) + 1
- set yCenter to ((the top of sprite 3 + the bottom of sprite 3) / 2) + 1
- set radius to (the width of sprite 3 / 2) - 2
- puppetSprite(4, 1)
- set the trails of sprite 4 to 1
- repeat with n = 0 to 360
- if the mouseDown then
- exit repeat
- end if
- set dy to float(radius) * float(sin(n * PI / 180.0))
- set dx to float(radius) * float(cos(n * PI / 180.0))
- drawLine(4, yCenter, xCenter, yCenter + dy, xCenter + dx)
- put "- " & n & " Degrees" into field "NDegree"
- updateStage()
- startTimer()
- if (n = 30) or (n = 60) or (n = 90) or (n = 180) or (n = 270) then
- repeat while the timer < (5 * 60)
- if the mouseDown then
- exit repeat
- end if
- end repeat
- end if
- end repeat
- puppetSprite(4, 0)
- set the trails of sprite 4 to 0
- end
-